//
// Created by hp on 2020-01-01.
//

#ifndef THUNDER_GAME_H
#define THUNDER_GAME_H
#include <iostream>
#include <Windows.h>
#include <bass.h>
#include <vender/glad/include/glad/glad.h>
#include <vender/GLFW/include/glfw3.h>
#include <vender/filesystem.h>
#include <Shader.h>
#include <vector>
using namespace std;
using namespace std;
typedef struct _point{
    float x;
    float y;
}point;
void convVert(float lx,float ly,float width,float height, float vertices[]);
enum GameState {
    GAME_ACTIVE,
    GAME_MENU,
    GAME_WIN
};

// Game holds all game-related state and functionality.
// Combines all game-related data into a single class for
// easy access to each of the components and manageability.
class Game
{
public:
    // Game state
    GameState              State;
    GLboolean              Keys[1024];
    static GLuint          Width;
    static GLuint          Height;

    // Constructor/Destructor
    Game(GLuint width,GLuint height);
    ~Game();

    // Initialize game state (load all shaders/textures/levels)
    GLFWwindow *createWindow();

    void init();

    // GameLoop
    char ProcessInput(GLFWwindow *window);
    void Update(GLfloat dt);
    void Render();
    void createMenu();
    static void convVert(float lx, float ly, float width, float height, float vertices[]);

};
#endif //THUNDER_GAME_H
